import request from '@/utils/request'

export function getList() {
  return request({
    url: '/api/a1/journals',
    method: 'get'
  })
}

export function createData(data) {
  return request({
    url: '/api/a1/journals',
    method: 'post',
    data
  })
}

export function updateData(data) {
  return request({
    url: '/api/a1/journals/' + data.id,
    method: 'put',
    data
  })
}

export function deleteData(data) {
  return request({
    url: '/api/a1/journals/' + data.id,
    method: 'delete'
  })
}
